import request from '@/utils/request'

// 查询我的报名列表
export function listMyEnrollment(query) {
  return request({
    url: '/education/myEnrollment/list',
    method: 'get',
    params: query
  })
}

// 查询我的报名详细
export function getMyEnrollment(enrollmentId) {
  return request({
    url: '/education/myEnrollment/' + enrollmentId,
    method: 'get'
  })
}

// 取消报名
export function cancelEnrollment(enrollmentId) {
  return request({
    url: '/education/myEnrollment/cancel/' + enrollmentId,
    method: 'put'
  })
}

// 查询我的学分统计
export function getMyCredits() {
  return request({
    url: '/education/myEnrollment/credits',
    method: 'get'
  })
} 